\documentclass[11pt]{article}

% ISO 216

% B4
%\usepackage[paperwidth=250mm, paperheight=353mm, top=15mm, bottom=15mm, left=15mm, right=15mm]{geometry}

% A4
%\usepackage[paperwidth=210mm, paperheight=297mm, top=15mm, bottom=15mm, left=15mm, right=15mm]{geometry}

% B5
\usepackage[paperwidth=176mm, paperheight=250mm, top=15mm, bottom=15mm, left=15mm, right=15mm]{geometry}

% A5
%\usepackage[paperwidth=148mm, paperheight=210mm, top=15mm, bottom=15mm, left=15mm, right=15mm]{geometry}


\usepackage{amsfonts}
\usepackage{amsmath}
\usepackage{amssymb}

\usepackage[utf8]{inputenc}

\linespread{1.2}
\parskip=5pt

\begin{document}
\begin{center}\begin{bfseries}Technical Note\end{bfseries}\end{center}

\begin{center}2014-04-11\end{center}

\begin{flushleft}
Let the vertex set \begin{math}V=\{v_{0}, v_{1}, v_{2}\}\end{math} be the 
vertices of the referenced triangle element.  The coordinates of the three 
vertices are \begin{math}v_{0}=(0, 0)\end{math}, 
\begin{math}v_{1}=(1, 0)\end{math}, and \begin{math}v_{2}=(0, 1)\end{math} in 
\begin{math}rs\end{math}-plane.  Let the vertex set 
\begin{math}W=\{w_{0}, w_{1}, w_{2}\}\end{math} be the vertices of the physical 
element with coordinates \begin{math}w_{0}=(x_{0}, y_{0})\end{math}, 
\begin{math}w_{0}=(x_{1}, y_{1})\end{math}, and 
\begin{math}w_{0}=(x_{2}, y_{2})\end{math} in \begin{math}xy\end{math}-plane.
Let \begin{math}F\end{math} be a linear mapping from physical element to 
referenced element such that \begin{math}f(w_{0})=v_{0}\end{math}, 
\begin{math}f(w_{1})=v_{1}\end{math}, and \begin{math}f(w_{2})=v_{2}\end{math}.
Let \begin{math}F\end{math} be the matrix as the following
\begin{displaymath}
F=\left[
\begin{array}{cc}
f_{11} & f_{12} \\
f_{21} & f_{22}
\end{array}
\right]
\end{displaymath}
Now, we consider the requirements, then
\begin{equation}
f(w_{0})=\left[
\begin{array}{cc}
f_{11} & f_{12} \\
f_{21} & f_{22}
\end{array}
\right]
\left[
\begin{array}{c}
x_{0} - x_{0} \\
y_{0} - y_{0}
\end{array}
\right]
=
\left[
\begin{array}{c}
0 \\
0
\end{array}
\right]
=v_{0}
\end{equation}
\begin{equation}
f(w_{1})=\left[
\begin{array}{cc}
f_{11} & f_{12} \\
f_{21} & f_{22}
\end{array}
\right]
\left[
\begin{array}{c}
x_{1} - x_{0} \\
y_{1} - y_{0}
\end{array}
\right]
=
\left[
\begin{array}{c}
1 \\
0
\end{array}
\right]
=v_{1}
\end{equation}
\begin{equation}
f(w_{2})=\left[
\begin{array}{cc}
f_{11} & f_{12} \\
f_{21} & f_{22}
\end{array}
\right]
\left[
\begin{array}{c}
x_{2} - x_{0} \\
y_{2} - y_{0}
\end{array}
\right]
=
\left[
\begin{array}{c}
0 \\
1
\end{array}
\right]
=v_{2},
\end{equation}
and to find the solution for  \begin{math}F\end{math}, that is 
\begin{math}f_{11}\end{math}, \begin{math}f_{12}\end{math}, 
\begin{math}f_{21}\end{math}, and \begin{math}f_{22}\end{math}.  Let 
\begin{math}p_{1}=x_{1}-x_{0}\end{math}, 
\begin{math}q_{1}=y_{1}-y_{0}\end{math}, 
\begin{math}p_{2}=x_{2}-x_{0}\end{math}, and
\begin{math}q_{1}=y_{1}-y_{0}\end{math}

\begin{displaymath}
\left\{
\begin{array}{l}
p_{1}f_{11}+q_{1}f_{12}=1 \\
p_{1}f_{21}+q_{1}f_{22}=0 \\
p_{2}f_{11}+q_{2}f_{12}=0 \\
p_{2}f_{21}+q_{2}f_{22}=1
\end{array}
\right.
\Rightarrow
\left[
\begin{array}{cccc}
p_{1} & q_{1} & 0 & 0 \\
p_{2} & q_{2} & 0 & 0 \\
0 & 0 & p_{1} & q_{1} \\
0 & 0 & p_{2} & q_{2}
\end{array}
\right]
\left[
\begin{array}{c}
f_{11} \\ f_{12} \\ f_{21} \\ f_{22}
\end{array}
\right]
=
\left[
\begin{array}{c}
1 \\ 0 \\ 0 \\ 1
\end{array}
\right]
\end{displaymath}
Let 
\begin{math}\displaystyle
A=\left[\begin{array}{cc}p_{1} & q_{1} \\ p_{2} & q_{2}\end{array}\right]
\end{math}, 
then \begin{math}\det(A)=p_{1}q_{2}-q_{1}p_{2}\end{math} and
\begin{math}\displaystyle
A^{-1}=\frac{1}{\det(A)}
\left[
\begin{array}{rr}
q_{2} & -q_{1} \\ -p_{2} & p_{1}
\end{array}
\right]
\end{math}

Therefore, \begin{math}\displaystyle f_{11}=\frac{q_{2}}{\det(A)}\end{math}, 
\begin{math}\displaystyle f_{12}=-\frac{p_{2}}{\det(A)}\end{math}, 
\begin{math}\displaystyle f_{21}--\frac{q_{1}}{\det(A)}\end{math}, and
\begin{math}\displaystyle f_{22}=\frac{p_{1}}{\det(A)}\end{math}.
\end{flushleft}

Let \begin{math}w=(x,y)\end{math} be a point in physical element.  The mapping 
\begin{math}f(w)=f(x,y)=(r,s)\end{math} is given by
\begin{equation}
f(x,y)=\frac{1}{\det(A)}
\left[
\begin{array}{rr}
q_{2} & -p_{2} \\
-q_{1} & p_{1}
\end{array}
\right]
\left[
\begin{array}{c}
x-x_{0} \\
y-y_{0}
\end{array}
\right]
\end{equation}
That is 
\begin{equation}
r=\frac{1}{\det(A)}(q_{2}(x-x_{0})-p_{2}(y-y_{0}))
=\frac{1}{\det(A)}(q_{2}x-p_{2}y-q_{2}x_{0}+p_{2}y_{0})
\end{equation}
\begin{equation}
s=\frac{1}{\det(A)}(p_{1}(y-y_{0})-q_{1}(x-x_{0}))
=\frac{1}{\det(A)}(p_{1}y-q_{1}x-p_{1}y_{0}+q_{1}x_{0})
\end{equation}

\begin{displaymath}
\frac{dr}{dx}=\frac{1}{\det(A)}q_{2},
\qquad
\frac{dr}{dy}=-\frac{1}{\det(A)}p_{2}
\end{displaymath}

\begin{displaymath}
\frac{ds}{dx}=-\frac{1}{\det(A)}q_{1}.
\qquad
\frac{ds}{dy}=\frac{1}{\det(A)}p_{1},
\end{displaymath}

Let \begin{math}\phi _{0}\end{math}, \begin{math}\phi _{1}\end{math},
\begin{math}\phi _{2}\end{math} be linear basis of referenced element, and 
\begin{math}\psi _{0}\end{math}, \begin{math}\psi _{1}\end{math}, 
\begin{math}\psi _{2}\end{math} be linear basis of physical element.

\begin{align*}
\phi _{0}(r,s) & =1-r-s \\
\phi _{1}(r,s) & =r \\
\phi _{2}(r,s) & =s
\end{align*}

\begin{align}
\nabla \phi _{0}
=(\frac{\partial \phi _{0}}{\partial r},\frac{\partial \phi _{0}}{\partial s})
& =(-1,-1) \\
\nabla \phi _{1}
=(\frac{\partial \phi _{1}}{\partial r},\frac{\partial \phi _{1}}{\partial s})
& =(1,0) \\
\nabla \phi _{2}
=(\frac{\partial \phi _{2}}{\partial r},\frac{\partial \phi _{2}}{\partial s})
& =(0,1)
\end{align}

\begin{align*}
\psi _{0}(x,y) & = a_{0}x+b_{0}y+c_{0} \\
\psi _{1}(x,y) & = a_{1}x+b_{1}y+c_{1} \\
\psi _{2}(x,y) & = a_{2}x+b_{2}y+c_{2}
\end{align*}

\begin{equation}
\nabla \psi _{0}
=(\frac{\partial \psi _{0}}{\partial x},\frac{\partial \psi _{0}}{\partial y})
=(a_{0},b_{0})
\end{equation}

\begin{equation}
\nabla \psi _{1}
=(\frac{\partial \psi _{1}}{\partial x},\frac{\partial \psi _{1}}{\partial y})
=(a_{1},b_{1})
\end{equation}

\begin{equation}
\nabla \psi _{2}
=(\frac{\partial \psi _{2}}{\partial x},\frac{\partial \psi _{2}}{\partial y})
=(a_{2},b_{2})
\end{equation}

\begin{equation}
\left\{
\begin{array}{rl}
x_{0}a_{0}+y_{0}b_{0}+c_{0} & =1 \\
x_{1}a_{0}+y_{1}b_{0}+c_{0} & =0 \\
x_{2}a_{0}+y_{2}b_{0}+c_{0} & =0 
\end{array}
\right.
\Rightarrow
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
x_{1} & y_{1} & 1 \\
x_{2} & y_{2} & 1
\end{array}
\right]
\left[\begin{array}{c}a_{0} \\ b_{0} \\ c_{0} \end{array}\right]
=\left[\begin{array}{c}1 \\ 0 \\ 0 \end{array}\right]
\end{equation}

\begin{equation}
\left\{
\begin{array}{rl}
x_{0}a_{1}+y_{0}b_{1}+c_{1} & =0 \\
x_{1}a_{1}+y_{1}b_{1}+c_{1} & =1 \\
x_{2}a_{1}+y_{2}b_{1}+c_{1} & =0 
\end{array}
\right.
\Rightarrow
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
x_{1} & y_{1} & 1 \\
x_{2} & y_{2} & 1
\end{array}
\right]
\left[\begin{array}{c}a_{1} \\ b_{1} \\ c_{1} \end{array}\right]
=\left[\begin{array}{c}0 \\ 1 \\ 0 \end{array}\right]
\end{equation}

\begin{equation}
\left\{
\begin{array}{rl}
x_{0}a_{2}+y_{0}b_{2}+c_{2} & =0 \\
x_{1}a_{2}+y_{1}b_{2}+c_{2} & =0 \\
x_{2}a_{2}+y_{2}b_{2}+c_{2} & =1 
\end{array}
\right.
\Rightarrow
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
x_{1} & y_{1} & 1 \\
x_{2} & y_{2} & 1
\end{array}
\right]
\left[\begin{array}{c}a_{2} \\ b_{2} \\ c_{2} \end{array}\right]
=\left[\begin{array}{c}0 \\ 0 \\ 1 \end{array}\right]
\end{equation}

\begin{equation}
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
x_{1} & y_{1} & 1 \\
x_{2} & y_{2} & 1
\end{array}
\right]
\left[\begin{array}{ccc}
a_{0} & a_{1} & a_{2} \\ b_{0} & b_{1} & b_{2} \\ c_{0} & c_{1} & c_{2}
\end{array}\right]
=\left[\begin{array}{ccc}
1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{array}\right]
\end{equation}

\begin{displaymath}
\Rightarrow
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
x_{1} - x_{0} & y_{1} - y_{0} & 0 \\
x_{2} - x_{0} & y_{2} - y_{0} & 0
\end{array}
\right]
\left[\begin{array}{ccc}
a_{0} & a_{1} & a_{2} \\ b_{0} & b_{1} & b_{2} \\ c_{0} & c_{1} & c_{2}
\end{array}\right]
=\left[\begin{array}{rrr}
1 & 0 & 0 \\ -1 & 1 & 0 \\ -1 & 0 & 1 \end{array}\right]
\end{displaymath}

\begin{displaymath}
\Rightarrow
\left[
\begin{array}{ccc}
x_{0} & y_{0} & 1 \\
p_{1} & q_{1} & 0 \\
p_{2} & q_{2} & 0
\end{array}
\right]
\left[\begin{array}{ccc}
a_{0} & a_{1} & a_{2} \\ b_{0} & b_{1} & b_{2} \\ c_{0} & c_{1} & c_{2}
\end{array}\right]
=\left[\begin{array}{rrr}
1 & 0 & 0 \\ -1 & 1 & 0 \\ -1 & 0 & 1 \end{array}\right]
\end{displaymath}

% PSI_{0}
Solve for \begin{math}\psi _{0}\end{math},
\begin{displaymath}
\Rightarrow
\left[\begin{array}{ccc}
x_{0} & y_{0} & 1 \\ p_{1} & q_{1} & 0 \\ p_{2} & q_{2} & 0
\end{array}\right]
\left[\begin{array}{c}a_{0} \\ b_{0} \\ c_{0}\end{array}\right]
=\left[\begin{array}{r}1 \\ -1 \\ -1\end{array}\right]
\end{displaymath}

\begin{displaymath}
\Rightarrow
\left[\begin{array}{cc}p_{1} & q_{1} \\p_{2} & q_{2}\end{array}\right]
\left[\begin{array}{c}a_{0} \\ b_{0}\end{array}\right]
=\left[\begin{array}{r}-1 \\ -1\end{array}\right]
\end{displaymath}

\begin{displaymath}
\left[\begin{array}{c}a_{0} \\ b_{0}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{c}q_{1}-q_{2} \\ p_{2}-p_{1}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{c}y_{1}-y_{2} \\ x_{2}-x_{1}\end{array}\right]
\end{displaymath}

\begin{equation}
a_{0}=\frac{1}{\det(A)}(y_{1}-y_{2})=\frac{1}{\det(A)}(q_{1}-q_{2})
\end{equation}

\begin{equation}
b_{0}=\frac{1}{\det(A)}(x_{2}-x_{1})=\frac{1}{\det(A)}(p_{2}-p_{1})
\end{equation}

\begin{equation}
c_{0}
=\frac{1}{\det(A)}(x_{0}(y_{2}-y_{1})+y_{0}(x_{1}-x_{2}))
=\frac{1}{\det(A)}(x_{0}(q_{2}-q_{1})+y_{0}(p_{1}-p_{2}))
\end{equation}

% PSI_{1}
Solve for \begin{math}\psi _{1}\end{math},
\begin{displaymath}
\Rightarrow
\left[\begin{array}{ccc}
x_{0} & y_{0} & 1 \\ p_{1} & q_{1} & 0 \\ p_{2} & q_{2} & 0
\end{array}\right]
\left[\begin{array}{c}a_{1} \\ b_{1} \\ c_{1}\end{array}\right]
=\left[\begin{array}{r}0 \\ 1 \\ 0\end{array}\right]
\end{displaymath}

\begin{displaymath}
\Rightarrow
\left[\begin{array}{cc}p_{1} & q_{1} \\p_{2} & q_{2}\end{array}\right]
\left[\begin{array}{c}a_{1} \\ b_{1}\end{array}\right]
=\left[\begin{array}{r}1 \\ 0\end{array}\right]
\end{displaymath}

\begin{displaymath}
\left[\begin{array}{c}a_{1} \\ b_{1}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{r}q_{2} \\ -p_{2}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{r}y_{2} - y_{0} \\ x_{0} - x_{2}\end{array}\right]
\end{displaymath}

\begin{equation}
a_{1}=\frac{1}{\det(A)}(y_{2}-y_{0})=\frac{1}{\det(A)}q_{2}
\end{equation}

\begin{equation}
b_{1}=\frac{1}{\det(A)}(x_{0}-x_{2})=-\frac{1}{\det(A)}p_{2}
\end{equation}

% PSI_{2}
Solve for \begin{math}\psi _{2}\end{math},
\begin{displaymath}
\Rightarrow
\left[\begin{array}{ccc}
x_{0} & y_{0} & 1 \\ p_{1} & q_{1} & 0 \\ p_{2} & q_{2} & 0
\end{array}\right]
\left[\begin{array}{c}a_{2} \\ b_{2} \\ c_{2}\end{array}\right]
=\left[\begin{array}{r}0 \\ 0 \\ 1\end{array}\right]
\end{displaymath}

\begin{displaymath}
\Rightarrow
\left[\begin{array}{cc}p_{1} & q_{1} \\p_{2} & q_{2}\end{array}\right]
\left[\begin{array}{c}a_{2} \\ b_{2}\end{array}\right]
=\left[\begin{array}{r}0 \\ 1\end{array}\right]
\end{displaymath}

\begin{displaymath}
\left[\begin{array}{c}a_{2} \\ b_{2}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{r}-q_{1} \\ p_{1}\end{array}\right]
=\frac{1}{\det(A)}
\left[\begin{array}{r}y_{0} - y_{1} \\ x_{1} - x_{0}\end{array}\right]
\end{displaymath}

\begin{equation}
a_{2}=\frac{1}{\det(A)}(y_{0}-y_{1})=-\frac{1}{\det(A)}q_{1}
\end{equation}

\begin{equation}
b_{2}=\frac{1}{\det(A)}(x_{1}-x_{0})=\frac{1}{\det(A)}p_{1}
\end{equation}


\end{document}
